package com.jingyanku.service.impl;


import com.base.service.impl.ServiceImpl;
import com.jingyanku.pojo.Board;
import com.jingyanku.service.IBoardService;


public class BoardServiceImpl<T extends Board> extends ServiceImpl<T> implements
		IBoardService<T> {

	@Override
	

	public boolean create(T board) {

		if (dao.createQuery(
				" from Board b where b.deleted = false and b.name ='" +board.getName().trim() +"'").list().size()> 0) {

			return false;
		}else{

		dao.create(board);
		return true;}
	}

}
